﻿@model Yunwei.Web.Models.OrderViewModel

@{
    ViewBag.Title = "Detail";
}
<div class="row">
    <div class="col-lg-12">
        <h1 class="page-header">订单详情</h1>
    </div>
    <div class="col-lg-6">
        @*<a class="btn btn-primary btn-circle" href="/RRShop/Order/List/@ViewBag.Id"><i class="fa fa-reply"></i></a>*@
        <a class="btn btn-primary btn-circle" href="/RRShop/Home/Index/@ViewBag.Id"><i class="fa fa-reply"></i></a>
    </div>
</div>

<div>
    <form action="/RRShop/Order/Edit" method="post">
        <dl class="dl-horizontal">
            <dt>
                @Html.DisplayNameFor(model => model.OrderNo)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.OrderNo)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.OrderTime)
            </dt>

            <dd>
                @Model.OrderTime.ToString("yyyy-MM-dd HH:mm:ss")
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.MealTime)
            </dt>

            <dd>
                @Model.MealTime.ToString("yyyy-MM-dd HH:mm")
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.PayType)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.PayTypeString)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.BuyerName)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.BuyerName)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.BuyerPhone)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.BuyerPhone)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.Remark)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.Remark)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.DinnerTable_Id)
            </dt>

            <dd>
                @Model.DinnerTableViewModel.Name
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.RoomPrice)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.RoomPrice)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.MealFee)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.MealFee)
            </dd>

            <dt>
                @Html.DisplayNameFor(model => model.TotalPrice)
            </dt>

            <dd>
                @Html.DisplayFor(model => model.TotalPrice)
            </dd>

            <dt>
                菜单
            </dt>
            <dd>
                <ul style="display:block;">
                    @foreach (var food in Model.Foods)
                    {
                        <li style="float:left;list-style:none;text-align:center;display:block;">
                            <a style="display:block;padding:5px;"><img style="width:100px;height:100px;" src="@food.Food.Avatar" /><br />@food.Food.Name</a>
                        </li>
                    }
                </ul>
            </dd>

            <dt style="color:red;font-weight:bold;">
                @Html.DisplayNameFor(model => model.Status)
            </dt>

            <dd>
                @Html.DropDownListFor(model => model.Status, Model.StatusItems, new { @class = "form-control" })
            </dd>
            
            <dt>
                @Html.HiddenFor(model => model.Restaurant_Id)
                @Html.HiddenFor(model => model.Id)
            </dt>
            <dd>
                <input type="submit" class="btn btn-success" value="保存" />
            </dd>
        </dl>
    </form>
</div>